﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;

namespace HZ.DrugTrade.Web.Admin.SystemManage
{
    public partial class ComPwdPrint : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                if (Session["result"] != null)
                {
                    Model.View.CompanySendPwd result = (Model.View.CompanySendPwd)Session["result"];

                    ltrComName.Text = result.CompanyName;
                    ltrComName0.Text = result.CompanyName;
                    ltrComName1.Text = result.CompanyName;
                    ltrDate.Text = DateTime.Now.ToLongDateString();
                    ltrDate1.Text = DateTime.Now.ToLongDateString();
                    ltrDate2.Text = DateTime.Now.ToLongDateString();
                    ltrName.Text = result.ContactPerson;
                    ltrPwd.Text = result.UserPwd;
                    ltrTel.Text = result.CellNo;
                    ltrUserName.Text = result.CompanyId;
                    ltrOperator.Text = result.SendOperator;
                    ltrOperateTime.Text = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
                    string type = result.CompanyType.ToString();


                    string tip_ComJY = "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;凭此用户名密码登陆系统填报本企业信息，用户名和密码是企业参加医用耗材网上集中采购的唯一身份识别，请在登陆系统后立即修改您的密码。（具体操作查看操作帮助！）";
                    ltrTip.Text = tip_ComJY;
                    if (type=="0")
                    {
                        ltrComType.Text = "生产企业";
                    }
                    else if(type=="1")
                    {
                        ltrComType.Text = "经营企业";
                    }
                    else if (type=="2")
                    {
                        ltrComType.Text = "配送企业";
                    }
                    else if (type=="3")
                    {
                        ltrComType.Text = "生产企业直接配送";
                    }
                    else if (type=="4")
                    {
                        ltrComType.Text = "经营企业直接配送";
                    }
                    else
                    {
                        ltrComType.Text = "";
                    }
                    //if (type == "1")
                    //{
                    //    ltrComType.Text = "配送企业";
                    //    ltrTip.Text = tip_ComJY;
                    //}
                    //else if (type == "2")
                    //{
                    //    ltrComType.Text = "经营企业(国内一级总代)";
                    //    ltrTip.Text = tip_ComSC;
                    //}

                }
            }
        }
    }
}
